import com.study.demo.controller.UserController;
import com.study.demo.service.CourseService;
import com.study.demo.service.CourseService2;
import com.study.demo.service.StudentService1;
import com.study.demo.service.StudentService2;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class App {
    public static void main(String[] args) {
        ApplicationContext context =
                new ClassPathXmlApplicationContext("Spring-config.xml");
        // CourseService
        CourseService courseService =
                context.getBean("courseService",CourseService.class);
        courseService.getSpecializedCourse();
        //CourseService2
        CourseService2 courseService2 =
                context.getBean("courseService2",CourseService2.class);
        courseService2.getSpecializedCourse();
    }
}
